
<!DOCTYPE html>
<html>
<head>
	<title>悦淘新房</title>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
	<link rel="stylesheet" href="${s.base}/mobile/base/css/weui.min.css">
	<link rel="stylesheet" href="${s.base}/mobile/base/css/jquery-weui.css">
	<link rel="stylesheet" href="${s.base}/mobile/wechat/css/base.css">
	<link rel="stylesheet" href="${s.base}/mobile/wechat/css/component.css">
</head>
<style type="text/css">
	.border_r{border-right: 0.01rem solid #EEE9F8;}
	html,body{background:#FBFBFB;}
	.xyg-xf{width:100%;height:9rem;background: #ffffff;}
	.xyg-card{width:96%; height:8rem;padding:0.5rem 2%;border-radius:0.2rem; position:relative; }
	.xyg-card-bg{width:100%; height:8rem;}
	.xyg-card-title{width:100%; height:1rem; line-height: 1rem; text-align:center; font-size:14px;letter-spacing: 0.1rem; position: absolute; top:1rem; left:0px; color:#FFFFFF; }
	.xyg-card-money{width:100%; height:4rem; line-height: 4rem; text-align:center; font-size:2rem;position: absolute; top:1.5rem; left:0px; color:#FFFFFF; }
	.xyg-card-money span{font-size:14px;}
	.xyg-card-list{width:100%; height:2rem;position: absolute; top:5.5rem; left:0px;}
	.xyg-card-list .xyg-card-list-item{width:49.5%; float: left;}
	.xyg-card-list .xyg-card-list-item .xyg-card-list-item-title{height:1rem; line-height: 1rem; text-align:center; font-size:14px;letter-spacing: 0.1rem; color:#FFFFFF;}
	.xyg-card-list .xyg-card-list-item .xyg-card-list-item-money{height:1rem; line-height: 1rem; text-align:center; font-size:14px;letter-spacing: 0.1rem; color:#FFFFFF;}

	.xyg-tab{width:96%; height:auto;padding:0rem 2%;background: #ffffff;}
	.xyg-tab-item{width:33.3%;float: left; line-height: 2rem; height:2rem;text-align: center; color:#ABABAB ;font-size: 14px;}
	.xyg-tab .tab-active{color:#000000;font-size: 14px; font-weight: bold;}

	.xyg-contentf{width:96%; height:auto;padding:0rem 2%;}
	.xyg-contentf-item{width:100%; height:3rem;padding:0.2rem 0px; border-radius: 0.5rem; background: #ffffff; margin-top: 0.2rem; box-shadow:0 0 0.2rem #f1f1f1 inset;}
	.xyg-contentf .xyg-contentf-item-img{width:20%; height:2.3rem; padding: 0.1rem 0px; float: left;}
	.xyg-contentf .xyg-contentf-item-img img{width:2.3rem; height:2.3rem; margin:0px auto;}
	.xyg-contentf .xyg-contentf-item-list{width:52%; margin-left: 2%; height: 100%; float: left;}
	.xyg-contentf .xyg-contentf-item-list .xyg-contentf-item-list-title{ width: 100%; line-height: 1.5rem; height: 1.5rem; font-size: 14px; color: #000000; text-align: left; font-weight: bold;}
	.xyg-contentf .xyg-contentf-item-list .xyg-contentf-item-list-time{ width: 100%; line-height: 1rem; height: 1rem;font-size: 12px; color: #999999; text-align: left;}
	.xyg-contentf .xyg-contentf-item-money{width:25%; height: 100%; float: left;color: #069AFE; line-height: 2.5rem; height:2.5rem; font-size: 16px; font-weight: bold;}
</style>

<body >
<div class="xyg-contentf" id="recordList" >

</div>

</body>
<script src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js"></script>
<script src="${s.base}/mobile/base/js/jquery-2.1.4.js" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/mobile/base/js/jquery-weui.js" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/mobile/base/js/component.js?12323434323232323232" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/mobile/wechat/fonts/iconfont.js"></script>
<script src="${s.base}/mobile/wechat/js/window_port.js"></script>
<script src="${s.base}/mobile/wechat/js/base.js"></script>
<!--js分享代码开始-->

<input type="hidden" value="${jSTicketShareResponse.appid}" id="appid" />
<input type="hidden" value="${jSTicketShareResponse.fxTitle}" id="fxTitle" />
<input type="hidden" value="${jSTicketShareResponse.fxImgUrl}" id="fxImgUrl" />
<input type="hidden" value="${jSTicketShareResponse.fxDesc}" id="fxDesc" />
<input type="hidden" value="${jSTicketShareResponse.fxUrl}" id="fxUrl" />
<input type="hidden" value="${jSTicketShareResponse.nonceStr}" id="nonceStr" />
<input type="hidden" value="${jSTicketShareResponse.timestamp}" id="timestamp" />
<input type="hidden" value="${jSTicketShareResponse.signature}" id="signature" />
<script src="${s.base}/mobile/wechat/js/share.js"></script>
<!--js分享代码结束-->
<script type="text/javascript">
    var memberId='${memberId}';
    var cardNo='${webMember.cardNo}';
    var currentType="";
    $(document).ready(function(e) {
        initDate();
    });

    function initDate() {
        //初始化商品
        initProduct();
    }


    function changeType(type,obj) {
        currentType=type;
        pageNum = 0;
        $(".xyg-tab .xyg-tab-item").removeClass("tab-active");
        $(obj).addClass("tab-active");
        $("#recordList").html("");
        if(isDestroy){
            initProduct();
        }else{
            sendPost();
        }
    }


    var memberId='${memberId}';
    var pageNum = 0;
    var pageSize = 5;
    var loading = false;  //状态标记
    var isDestroy = false;  //状态标记
    /**
     * 初始化内容页面信息
     * @param cityId
     */
    function initProduct() {
        isDestroy = false;
        $(document.body).infinite().on("infinite", function () {
            if (loading) return;
            loading = true;
            sendPost();
        });
        sendPost();
    }

    function sendPost() {
        pageNum++;
        $.fn.postMethodAll("/weChat/myMember/page",{'pageNum':pageNum,'pageSize':pageSize,'oneCardNo':cardNo},function (result) {
            if (result.data != null && result.data.length > 0) {
                result.data.forEach(function (item,key,mapObj) {
                    var str='<div class="xyg-contentf-item" >\
                        <div class="xyg-contentf-item-img border_r">\
                        <img src="'+item.headImage+'"/>\
                        </div>\
                        <div class="xyg-contentf-item-list">\
                        <div class="xyg-contentf-item-list-title font-grade-one">\
                      '+item.nickName+'\
                    </div>\
                    <div class="xyg-contentf-item-list-time">\
                        关注时间：'+item.createTime+'\
                    </div>\
                    </div>\
                        <div class="clearBoth"></div>\
                        </div>';
                    $("#recordList").append(str);
                });
                loading = false;
                if (!result.hasNextPage) {
                    $(document.body).destroyInfinite();
                    isDestroy=true;
                }
            } else {
                $(document.body).destroyInfinite();
                isDestroy=true;
            }
        });
    }
</script>
</html>
